﻿/*
	Copyright (C) 2019 Zongming Liu <1849059316@qq.com>

	This program is free software; you can redistribute it and/or modify
	it under the terms of the GNU General Public License as published by
	the Free Software Foundation; either version 2 of the License, or
	(at your option) any later version.
	
	This program is distributed in the hope that it will be useful,
	but WITHOUT ANY WARRANTY; without even the implied warranty of
	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
	GNU General Public License for more details.
	
	You should have received a copy of the GNU General Public License along
	with this program; if not, write to the Free Software Foundation, Inc.,
	51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/

#ifndef BatDrawCommand_h__
#define BatDrawCommand_h__

#include "../base/VertexType.h"
#include <vector>

namespace SkyEngine2d
{
	
	using VertexVector = std::vector<VertexPositionColorTexture>;
	using IndexVector =std::vector<UINT>;
	
	class Material;
	class IDirectRender;
	
	//! 自动批处理命令接口
	class SGE_API IBatDrawCommand
	{
	public:
		virtual void use(IDirectRender * d3d_interface)=0;
		virtual const VertexVector & getVertexBuffer()const = 0;
		virtual const IndexVector & getIndexBuffer()const = 0;
		virtual Material & getMaterial() = 0;
		virtual int getIndexCount()const = 0;
		virtual int getVertexCount()const = 0;
	};
}

#endif // BatDrawCommand_h__
